package com.bing.services;

import com.bing.entity.Post;

import java.util.List;
import java.util.Set;

/**
 * Created by kaibb on 15-11-28.
 */

public interface BlogService {
    Long createPost(Post post);

    void updatePost(Post post);

    void deletePost(Long id);

    long getPostNum();

    List<Post> getPostsPaged(int pageNo, int pageSize);

    List<Post> getHotPosts(int size);

    List<Post> getPostsPagedByTag(int pageNo, int pageSize, List<String> tags);

    Post getPost(Long id);
    Post getPostByTitle(String title);

    Post getPre(Long id);

    Post getNext(Long id);

    Set<String> getTags();
}
